Optimal. Leaf size=148 \[ -\frac {(4 a-b) x}{2 b^3}+\frac {a^{3/2} (4 a+5 b) \tan ^{-1}\left (\frac {\sqrt {a+b} \tan (c+d x)}{\sqrt {a}}\right )}{2 b^3 (a+b)^{3/2} d}-\frac {a (2 a+b) \tan (c+d x)}{2 b^2 (a+b) d \left (a+(a+b) \tan ^2(c+d x)\right )}-\frac {\sin ^2(c+d x) \tan (c+d x)}{2 b d \left (a+(a+b) \tan ^2(c+d x)\right )} \]
[Out]
________________________________________________________________________________________
Rubi [A]
time = 0.18, antiderivative size = 148, normalized size of antiderivative = 1.00, number of steps
used = 6, number of rules used = 6, integrand size = 23, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.261, Rules used = {3266, 481, 592,
536, 209, 211} \begin {gather*} \frac {a^{3/2} (4 a+5 b) \text {ArcTan}\left (\frac {\sqrt {a+b} \tan (c+d x)}{\sqrt {a}}\right )}{2 b^3 d (a+b)^{3/2}}-\frac {x (4 a-b)}{2 b^3}-\frac {a (2 a+b) \tan (c+d x)}{2 b^2 d (a+b) \left ((a+b) \tan ^2(c+d x)+a\right )}-\frac {\sin ^2(c+d x) \tan (c+d x)}{2 b d \left ((a+b) \tan ^2(c+d x)+a\right )} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
Rule 209
Rule 211
Rule 481
Rule 536
Rule 592
Rule 3266
Rubi steps
\begin {align*} \int \frac {\sin ^6(c+d x)}{\left (a+b \sin ^2(c+d x)\right )^2} \, dx &=\frac {\text {Subst}\left (\int \frac {x^6}{\left (1+x^2\right )^2 \left (a+(a+b) x^2\right )^2} \, dx,x,\tan (c+d x)\right )}{d}\\ &=-\frac {\sin ^2(c+d x) \tan (c+d x)}{2 b d \left (a+(a+b) \tan ^2(c+d x)\right )}+\frac {\text {Subst}\left (\int \frac {x^2 \left (3 a+(-a+b) x^2\right )}{\left (1+x^2\right ) \left (a+(a+b) x^2\right )^2} \, dx,x,\tan (c+d x)\right )}{2 b d}\\ &=-\frac {a (2 a+b) \tan (c+d x)}{2 b^2 (a+b) d \left (a+(a+b) \tan ^2(c+d x)\right )}-\frac {\sin ^2(c+d x) \tan (c+d x)}{2 b d \left (a+(a+b) \tan ^2(c+d x)\right )}+\frac {\text {Subst}\left (\int \frac {2 a (2 a+b)-2 \left (2 a^2+2 a b-b^2\right ) x^2}{\left (1+x^2\right ) \left (a+(a+b) x^2\right )} \, dx,x,\tan (c+d x)\right )}{4 b^2 (a+b) d}\\ &=-\frac {a (2 a+b) \tan (c+d x)}{2 b^2 (a+b) d \left (a+(a+b) \tan ^2(c+d x)\right )}-\frac {\sin ^2(c+d x) \tan (c+d x)}{2 b d \left (a+(a+b) \tan ^2(c+d x)\right )}-\frac {(4 a-b) \text {Subst}\left (\int \frac {1}{1+x^2} \, dx,x,\tan (c+d x)\right )}{2 b^3 d}+\frac {\left (a^2 (4 a+5 b)\right ) \text {Subst}\left (\int \frac {1}{a+(a+b) x^2} \, dx,x,\tan (c+d x)\right )}{2 b^3 (a+b) d}\\ &=-\frac {(4 a-b) x}{2 b^3}+\frac {a^{3/2} (4 a+5 b) \tan ^{-1}\left (\frac {\sqrt {a+b} \tan (c+d x)}{\sqrt {a}}\right )}{2 b^3 (a+b)^{3/2} d}-\frac {a (2 a+b) \tan (c+d x)}{2 b^2 (a+b) d \left (a+(a+b) \tan ^2(c+d x)\right )}-\frac {\sin ^2(c+d x) \tan (c+d x)}{2 b d \left (a+(a+b) \tan ^2(c+d x)\right )}\\ \end {align*}
________________________________________________________________________________________
Mathematica [A]
time = 1.04, size = 106, normalized size = 0.72 \begin {gather*} \frac {-2 (4 a-b) (c+d x)+\frac {2 a^{3/2} (4 a+5 b) \tan ^{-1}\left (\frac {\sqrt {a+b} \tan (c+d x)}{\sqrt {a}}\right )}{(a+b)^{3/2}}+b \left (-1-\frac {2 a^2}{(a+b) (2 a+b-b \cos (2 (c+d x)))}\right ) \sin (2 (c+d x))}{4 b^3 d} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Maple [A]
time = 0.31, size = 134, normalized size = 0.91
method | result | size |
derivativedivides | \(\frac {\frac {a^{2} \left (-\frac {b \tan \left (d x +c \right )}{2 \left (a +b \right ) \left (a \left (\tan ^{2}\left (d x +c \right )\right )+b \left (\tan ^{2}\left (d x +c \right )\right )+a \right )}+\frac {\left (4 a +5 b \right ) \arctan \left (\frac {\left (a +b \right ) \tan \left (d x +c \right )}{\sqrt {a \left (a +b \right )}}\right )}{2 \left (a +b \right ) \sqrt {a \left (a +b \right )}}\right )}{b^{3}}-\frac {\frac {b \tan \left (d x +c \right )}{2 \left (\tan ^{2}\left (d x +c \right )\right )+2}+\frac {\left (4 a -b \right ) \arctan \left (\tan \left (d x +c \right )\right )}{2}}{b^{3}}}{d}\) | \(134\) |
default | \(\frac {\frac {a^{2} \left (-\frac {b \tan \left (d x +c \right )}{2 \left (a +b \right ) \left (a \left (\tan ^{2}\left (d x +c \right )\right )+b \left (\tan ^{2}\left (d x +c \right )\right )+a \right )}+\frac {\left (4 a +5 b \right ) \arctan \left (\frac {\left (a +b \right ) \tan \left (d x +c \right )}{\sqrt {a \left (a +b \right )}}\right )}{2 \left (a +b \right ) \sqrt {a \left (a +b \right )}}\right )}{b^{3}}-\frac {\frac {b \tan \left (d x +c \right )}{2 \left (\tan ^{2}\left (d x +c \right )\right )+2}+\frac {\left (4 a -b \right ) \arctan \left (\tan \left (d x +c \right )\right )}{2}}{b^{3}}}{d}\) | \(134\) |
risch | \(-\frac {2 a x}{b^{3}}+\frac {x}{2 b^{2}}+\frac {i {\mathrm e}^{2 i \left (d x +c \right )}}{8 b^{2} d}-\frac {i {\mathrm e}^{-2 i \left (d x +c \right )}}{8 b^{2} d}+\frac {i a^{2} \left (2 a \,{\mathrm e}^{2 i \left (d x +c \right )}+b \,{\mathrm e}^{2 i \left (d x +c \right )}-b \right )}{b^{3} \left (a +b \right ) d \left (-b \,{\mathrm e}^{4 i \left (d x +c \right )}+4 a \,{\mathrm e}^{2 i \left (d x +c \right )}+2 b \,{\mathrm e}^{2 i \left (d x +c \right )}-b \right )}-\frac {\sqrt {-a \left (a +b \right )}\, a^{2} \ln \left ({\mathrm e}^{2 i \left (d x +c \right )}-\frac {2 i \sqrt {-a \left (a +b \right )}+2 a +b}{b}\right )}{\left (a +b \right )^{2} d \,b^{3}}-\frac {5 \sqrt {-a \left (a +b \right )}\, a \ln \left ({\mathrm e}^{2 i \left (d x +c \right )}-\frac {2 i \sqrt {-a \left (a +b \right )}+2 a +b}{b}\right )}{4 \left (a +b \right )^{2} d \,b^{2}}+\frac {\sqrt {-a \left (a +b \right )}\, a^{2} \ln \left ({\mathrm e}^{2 i \left (d x +c \right )}+\frac {2 i \sqrt {-a \left (a +b \right )}-2 a -b}{b}\right )}{\left (a +b \right )^{2} d \,b^{3}}+\frac {5 \sqrt {-a \left (a +b \right )}\, a \ln \left ({\mathrm e}^{2 i \left (d x +c \right )}+\frac {2 i \sqrt {-a \left (a +b \right )}-2 a -b}{b}\right )}{4 \left (a +b \right )^{2} d \,b^{2}}\) | \(358\) |
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [A]
time = 0.56, size = 181, normalized size = 1.22 \begin {gather*} \frac {\frac {{\left (4 \, a^{3} + 5 \, a^{2} b\right )} \arctan \left (\frac {{\left (a + b\right )} \tan \left (d x + c\right )}{\sqrt {{\left (a + b\right )} a}}\right )}{{\left (a b^{3} + b^{4}\right )} \sqrt {{\left (a + b\right )} a}} - \frac {{\left (2 \, a^{2} + 2 \, a b + b^{2}\right )} \tan \left (d x + c\right )^{3} + {\left (2 \, a^{2} + a b\right )} \tan \left (d x + c\right )}{{\left (a^{2} b^{2} + 2 \, a b^{3} + b^{4}\right )} \tan \left (d x + c\right )^{4} + a^{2} b^{2} + a b^{3} + {\left (2 \, a^{2} b^{2} + 3 \, a b^{3} + b^{4}\right )} \tan \left (d x + c\right )^{2}} - \frac {{\left (d x + c\right )} {\left (4 \, a - b\right )}}{b^{3}}}{2 \, d} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [A]
time = 0.42, size = 623, normalized size = 4.21 \begin {gather*} \left [-\frac {4 \, {\left (4 \, a^{2} b + 3 \, a b^{2} - b^{3}\right )} d x \cos \left (d x + c\right )^{2} - 4 \, {\left (4 \, a^{3} + 7 \, a^{2} b + 2 \, a b^{2} - b^{3}\right )} d x + {\left (4 \, a^{3} + 9 \, a^{2} b + 5 \, a b^{2} - {\left (4 \, a^{2} b + 5 \, a b^{2}\right )} \cos \left (d x + c\right )^{2}\right )} \sqrt {-\frac {a}{a + b}} \log \left (\frac {{\left (8 \, a^{2} + 8 \, a b + b^{2}\right )} \cos \left (d x + c\right )^{4} - 2 \, {\left (4 \, a^{2} + 5 \, a b + b^{2}\right )} \cos \left (d x + c\right )^{2} - 4 \, {\left ({\left (2 \, a^{2} + 3 \, a b + b^{2}\right )} \cos \left (d x + c\right )^{3} - {\left (a^{2} + 2 \, a b + b^{2}\right )} \cos \left (d x + c\right )\right )} \sqrt {-\frac {a}{a + b}} \sin \left (d x + c\right ) + a^{2} + 2 \, a b + b^{2}}{b^{2} \cos \left (d x + c\right )^{4} - 2 \, {\left (a b + b^{2}\right )} \cos \left (d x + c\right )^{2} + a^{2} + 2 \, a b + b^{2}}\right ) + 4 \, {\left ({\left (a b^{2} + b^{3}\right )} \cos \left (d x + c\right )^{3} - {\left (2 \, a^{2} b + 2 \, a b^{2} + b^{3}\right )} \cos \left (d x + c\right )\right )} \sin \left (d x + c\right )}{8 \, {\left ({\left (a b^{4} + b^{5}\right )} d \cos \left (d x + c\right )^{2} - {\left (a^{2} b^{3} + 2 \, a b^{4} + b^{5}\right )} d\right )}}, -\frac {2 \, {\left (4 \, a^{2} b + 3 \, a b^{2} - b^{3}\right )} d x \cos \left (d x + c\right )^{2} - 2 \, {\left (4 \, a^{3} + 7 \, a^{2} b + 2 \, a b^{2} - b^{3}\right )} d x - {\left (4 \, a^{3} + 9 \, a^{2} b + 5 \, a b^{2} - {\left (4 \, a^{2} b + 5 \, a b^{2}\right )} \cos \left (d x + c\right )^{2}\right )} \sqrt {\frac {a}{a + b}} \arctan \left (\frac {{\left ({\left (2 \, a + b\right )} \cos \left (d x + c\right )^{2} - a - b\right )} \sqrt {\frac {a}{a + b}}}{2 \, a \cos \left (d x + c\right ) \sin \left (d x + c\right )}\right ) + 2 \, {\left ({\left (a b^{2} + b^{3}\right )} \cos \left (d x + c\right )^{3} - {\left (2 \, a^{2} b + 2 \, a b^{2} + b^{3}\right )} \cos \left (d x + c\right )\right )} \sin \left (d x + c\right )}{4 \, {\left ({\left (a b^{4} + b^{5}\right )} d \cos \left (d x + c\right )^{2} - {\left (a^{2} b^{3} + 2 \, a b^{4} + b^{5}\right )} d\right )}}\right ] \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Sympy [F(-1)] Timed out
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {Timed out} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [A]
time = 0.47, size = 223, normalized size = 1.51 \begin {gather*} \frac {\frac {{\left (4 \, a^{3} + 5 \, a^{2} b\right )} {\left (\pi \left \lfloor \frac {d x + c}{\pi } + \frac {1}{2} \right \rfloor \mathrm {sgn}\left (2 \, a + 2 \, b\right ) + \arctan \left (\frac {a \tan \left (d x + c\right ) + b \tan \left (d x + c\right )}{\sqrt {a^{2} + a b}}\right )\right )}}{{\left (a b^{3} + b^{4}\right )} \sqrt {a^{2} + a b}} - \frac {2 \, a^{2} \tan \left (d x + c\right )^{3} + 2 \, a b \tan \left (d x + c\right )^{3} + b^{2} \tan \left (d x + c\right )^{3} + 2 \, a^{2} \tan \left (d x + c\right ) + a b \tan \left (d x + c\right )}{{\left (a \tan \left (d x + c\right )^{4} + b \tan \left (d x + c\right )^{4} + 2 \, a \tan \left (d x + c\right )^{2} + b \tan \left (d x + c\right )^{2} + a\right )} {\left (a b^{2} + b^{3}\right )}} - \frac {{\left (d x + c\right )} {\left (4 \, a - b\right )}}{b^{3}}}{2 \, d} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Mupad [B]
time = 16.06, size = 2295, normalized size = 15.51 \begin {gather*} \text {Too large to display} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________